17. 练习: ORDER BY
练习
使用 ORDER BY 进行练习:
-
编写查询,返回 orders 表的先下单的前 10 个订单。包含
id
、occurred_at
和total_amt_usd
。
-
编写一个查询,返回 orders 表里
total_amt_usd
最高的5个 订单 。包括id
、account_id
和total_amt_usd
。
-
编写一个查询,基于
total
,返回 orders 表里的前 20 个 订单 。包括id
、account_id
和total
。
Workspace
This section contains either a workspace (it can be a Jupyter Notebook workspace or an online code editor work space, etc.) and it cannot be automatically downloaded to be generated here. Please access the classroom with your account and manually download the workspace to your local machine. Note that for some courses, Udacity upload the workspace files onto https://github.com/udacity , so you may be able to download them there.
Workspace Information:
- Default file path:
- Workspace type: sql-evaluator
- Opened files (when workspace is loaded): n/a